//获取职业散列表-----------------------------------------------------------------------
var nsgs_system_role_map;
function systemRoleList() {
	$.ajax({
		type:"post",
		url: ajaxUrl + "/api/1.0/nsgs/system/role.js",
		data:{
			token : window.localStorage.getItem('token'),
			sid: currentSID,
			gameId: 'BOXY',
			jobId : getTimeMs()
		},
		dataType:"json",
		success:function(request){
			console.log(request);		
			//数据整理为散列表
			nsgs_system_role_map = new HashTable(); 
			for(var i = 0 ; i < request.data.length ; i++){
				nsgs_system_role_map.put(request.data[i].id, request.data[i]);
			}
		},
		error:function(error){
			console.log(error);	
		}
	});		
}	
systemRoleList();
//获取世界地图散列表-----------------------------------------------------------------------
var nsgs_system_map_map;
function systemMapList() {
	$.ajax({
		type:"post",
		url: ajaxUrl + "/api/1.0/nsgs/system/map.js",
		data:{
			token : window.localStorage.getItem('token'),
			sid: currentSID,
			gameId: 'BOXY',
			jobId : getTimeMs()
		},
		dataType:"json",
		success:function(request){
			console.log(request);	
			//数据整理为散列表
			nsgs_system_map_map = new HashTable(); 
			for(var i = 0 ; i < request.data.length ; i++){
				nsgs_system_map_map.put(request.data[i].id, request.data[i]);
			}
		},
		error:function(error){
			console.log(error);	
		}
	});		
}
systemMapList();
//获取游戏怪物散列表-----------------------------------------------------------------------
var nsgs_system_monster_map;
function systemMonsterList() {
	$.ajax({
		type:"post",
		url: ajaxUrl + "/api/1.0/nsgs/system/monster.js",
		data:{
			token : window.localStorage.getItem('token'),
			sid: currentSID,
			gameId: 'BOXY',
			jobId : getTimeMs()
		},
		dataType:"json",
		success:function(request){
			console.log(request);	
			//数据整理为散列表
			nsgs_system_monster_map = new HashTable(); 
			for(var i = 0 ; i < request.data.length ; i++){
				nsgs_system_monster_map.put(request.data[i].id, request.data[i]);
			}
		},
		error:function(error){
			console.log(error);	
		}
	});		
}
systemMonsterList();
//获取系统道具散列表-----------------------------------------------------------------------
var nsgs_system_prop_map;
function systemPropList() {
	$.ajax({
		type:"post",
		url: ajaxUrl + "/api/1.0/nsgs/system/prop.js",
		data:{
			token : window.localStorage.getItem('token'),
			sid: currentSID,
			gameId: 'BOXY',
			jobId : getTimeMs()
		},
		dataType:"json",
		success:function(request){
			console.log(request);		
			//数据整理为散列表
			nsgs_system_prop_map = new HashTable(); 
			for(var i = 0 ; i < request.data.length ; i++){
				nsgs_system_prop_map.put(request.data[i].id, request.data[i]);
			}
		},
		error:function(error){
			console.log(error);	
		}
	});		
}
systemPropList();